<template style="background-color: #d4e1f1">
    <div  style="background: #D4E1F1;">
        <div style="color: rebeccapurple;margin-right: 900px;height: 10px"  ></div>
        <div style="color: rebeccapurple;margin-right: 80%" >
            <!--    查询-->
            <el-button    type="success"   @click="dialogVisible =true"  style="background: #D4E1F1; border-bottom-width: 0px;border-color:  #D4E1F1;width: 100px"><el-image style="width: 20px" src="https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2200157341,4136472267&fm=26&gp=0.jpg"></el-image> <font color="black" style="">添加</font></el-button>
            <el-button   type="success"   @click="deleteFileOrDirectory1(sels)"  style="background: #D4E1F1; border-bottom-width: 0px;border-color:  #D4E1F1;"><el-image style="width: 20px" src="https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=410472665,604040267&fm=26&gp=0.jpg"></el-image> <font color="black" style="">编辑</font></el-button>
            <el-button    type="success"   @click="deleteFileOrDirectory(sels)"  style="background: #D4E1F1; border-bottom-width: 0px;border-color:  #D4E1F1;width: 50px"><el-image style="width: 20px" src="https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2756049664,3387046994&fm=26&gp=0.jpg"></el-image> <font color="black" style="">删除</font></el-button>
        </div>
        <div>
            <el-form :inline="true" class="demo-form-inline">

                <!--      模糊-->
                <el-form-item style="margin-right: 100px">

                    房号 <el-select   v-model="search"

                                    size="mini"

                                    @focus="function33" style="width: 200px">
                    <el-option  v-for="item in fh"
                                :key="item.fhao"
                                :value="item.fhao"
                                :label="item.fhao"></el-option>
                </el-select>
                </el-form-item>
                <el-form-item style="margin-right: 100px">
                    <el-input
                            v-model="search2"
                            class="search_name"
                            size="mini"
                            placeholder="业主">
                    </el-input>
                </el-form-item>
                <el-form-item style="margin-right: 100px">
                    <el-input
                            v-model="search3"
                            class="search_name"
                            size="mini"
                            placeholder="联系电话">
                    </el-input>
                </el-form-item>
                <el-form-item>
                    <el-button
                            round
                            type="text"
                            @click="onSearch()"
                            style="background: #FEFEFE; width: 100px;height: 40px"
                    ><icon class="el-icon-search"/> 查询
                    </el-button>
                </el-form-item>
                <el-form-item>
                    <el-button
                            class="el-icon-refresh"
                            type="text"
                            @click="refreshData">刷新
                    </el-button>
                </el-form-item>
                <!--      增加-->

            </el-form>

            <el-table :data="users.slice((currentPage-1)*pagesize,currentPage*pagesize)"   @selection-change="selsChange">

                <el-table-column
                        type="selection"
                        width="55" >
                </el-table-column>

                <el-table-column label="操作">
                    <template slot-scope="scope">
                        <!--            <el-button size="mini" type="warning" @click="handleIsDisplay(scope.$index, scope.row)">-->
                        <!--              {{scope.row.lc=='显示'?'隐藏':'显示'}}-->
                        <!--            </el-button>-->
                        <el-button
                                size="mini"
                                style="background-color: yellowgreen"
                                @click="updateUser1(scope.$index, scope.row.sid)" :disabled="scope.row.crzyj == 1"
                        >催缴{{loadingbuttext}}
                        </el-button>

                    </template>
                    <!-- <el-button size="mini" type="danger" @click="handleRemove(scope.$index, scope.row)">删除</el-button> -->
                </el-table-column>
                <el-table-column label="房号" prop="fhao"/>
                <el-table-column label="业主名称" prop="name"/>
                <el-table-column label="联系电话" prop="zxgs"/>
                <el-table-column label="欠费金额" prop="crjgb"/>
                <el-table-column label="应缴费日期" prop="lc"/>
                <el-table-column label="亏欠天数" prop="wx"/>

                <el-table-column label="是否缴费" prop="crzyj">
                    <template slot-scope="scope">
                        <span v-if="scope.row.crzyj == 1">已缴费</span>
                        <span v-if="scope.row.crzyj == 0"><font color="red">未缴费</font></span>
                    </template>
                </el-table-column>

                <!--        <el-table-column label="出入证工本费" prop="crjgb"/>-->
                <!--        <el-table-column label="东或备案证" prop="dhbaz"/>-->
                <!--        <el-table-column label="维修保证金" prop="wx"/>-->
                <!--        <el-table-column label="垃圾清运费" prop="lj"/>-->
                <!--        <el-table-column label="装修工本费" prop="zx"/>-->
                <!--        <el-table-column label="泄水费" prop="xs"/>-->

            </el-table>

            <!--添加页面-->

            <el-dialog
                    title="商铺装修费用管理"
                    :visible.sync="dialogVisible"
                    append-to-body
                    :before-close="handleClose">

                <el-form   :model="ruleForm1" ref="ruleForm" label-width="100px" class="demo-ruleForm" :inline="true">
                    <!--        <el-form-item label="客户订单编号" prop="id">-->
                    <!--          <el-input v-model="formInline.id" style="width: 300px"></el-input>-->
                    <!--        </el-form-item>-->
                    <!--      </el-form-item>-->
                    <el-form-item label="业主名称" prop="name">
                        <el-select   v-model="ssld.name"
                                     @focus="function1"
                                     style="width: 150px" >
                            <el-option  v-for="item in ssld"
                                        :key="item.yid"
                                        :value="item.yid"
                                        :label="item.name"></el-option>
                        </el-select>
                    </el-form-item>

                    <el-form-item label="联系电话" prop="zxgs">
                        <el-input v-model="ruleForm1.zxgs" style="width: 150px"></el-input>
                    </el-form-item>

                    <!--                    <el-form-item label="业主名称" prop="name">-->
                    <!--                        <el-select   v-model="formInline.name"-->
                    <!--                                     @focus="function1"-->
                    <!--                                     @change="function2(formInline.name)" style="width: 300px">-->
                    <!--                            <el-option  v-for="item in formInline"-->
                    <!--                                        :key="item.yid"-->
                    <!--                                        :value="item.yid"-->
                    <!--                                        :label="item.name"></el-option>-->
                    <!--                        </el-select>-->
                    <!--                    </el-form-item>-->
                    <el-form-item label="房号" prop="fhao">
                        <el-select   v-model="fh.fhao"
                                     @focus="function33"
                                     style="width: 150px">
                            <el-option  v-for="item in fh"
                                        :key="item.id"
                                        :value="item.id"
                                        :label="item.fhao"></el-option>
                        </el-select>
                    </el-form-item>
                    <el-form-item label="应缴费日期" prop="lc">
                        <span class="demonstration"></span>
                        <el-date-picker
                                v-model="ruleForm1.lc"
                                align="right"
                                style="width: 150px"
                                type="date"
                                placeholder="选择日期"
                                :picker-options="pickerOptions">
                        </el-date-picker>
                    </el-form-item>

                    <el-form-item label="欠费金额" prop="crjgb">
                        <el-input v-model="ruleForm1.crjgb" style="width: 150px"></el-input>
                    </el-form-item>
                    <el-form-item label="亏钱天数" prop="wx">
                        <el-input v-model="ruleForm1.wx" style="width: 150px"></el-input>
                    </el-form-item>

                </el-form>
                <el-button round @click="cancel()" style="width: 150px;margin-left: 20px"   ><el-image src="" style="width: 20px"></el-image> 取 消</el-button>
                <el-button round @click="addUser()" type="primary" style="width: 150px"> <el-image src="https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1954671725,2900034259&fm=26&gp=0.jpg" style="width: 20px"></el-image>确定</el-button>

                <span slot="footer" class="dialog-footer">

            <span slot="footer" class="dialog-footer">

            </span>
    </span>
            </el-dialog>

            <!--修改页面-->
            <!--        <el-form-item label="客户订单编号" prop="id">-->

            <el-dialog
                    title="编辑"
                    :append-to-body='true'
                    :visible.sync="dialogUpdate1"

            >
                <el-form :model="ruleForm" ref="ruleForm" label-width="100px" class="demo-ruleForm" :inline="true">

                    <el-form-item label="业主名称" prop="name">
                        <el-select   v-model="ruleForm.name"
                                     @focus="function1"
                                     @change="function6(ruleForm.name)"
                                     style="width: 150px"  value="ruleForm.name" >
                            <el-option  v-for="item in ssld"
                                        :key="item.yid"
                                        :value="item.yid"
                                        :label="item.name"></el-option>
                        </el-select>
                    </el-form-item>
                    <el-form-item label="联系电话" prop="zxgs">
                        <el-input v-model="ruleForm.zxgs" style="width: 150px"></el-input>
                    </el-form-item>

                    <!--                    <el-form-item label="业主名称" prop="name">-->
                    <!--                        <el-select   v-model="formInline.name"-->
                    <!--                                     @focus="function1"-->
                    <!--                                     @change="function2(formInline.name)" style="width: 300px">-->
                    <!--                            <el-option  v-for="item in formInline"-->
                    <!--                                        :key="item.yid"-->
                    <!--                                        :value="item.yid"-->
                    <!--                                        :label="item.name"></el-option>-->
                    <!--                        </el-select>-->
                    <!--                    </el-form-item>-->
                    <el-form-item label="房号" prop="fhao">
                        <el-select   v-model="ruleForm.fhao"
                                     @focus="function33"
                                     @change="function8(ruleForm.fhao)"
                                     style="width: 150px">
                            <el-option  v-for="item in fh"
                                        :key="item.id"
                                        :value="item.id"
                                        :label="item.fhao"></el-option>
                        </el-select>
                    </el-form-item>
                    <el-form-item label="应缴费日期" prop="lc">
                        <span class="demonstration"></span>
                        <el-date-picker
                                v-model="ruleForm.lc"
                                align="right"
                                type="date"
                                style="width: 150px"
                                placeholder="选择日期"
                                :picker-options="pickerOptions">
                        </el-date-picker>
                    </el-form-item>

                    <el-form-item label="欠费金额" prop="crjgb">
                        <el-input v-model="ruleForm.crjgb" style="width: 150px"></el-input>
                    </el-form-item>
                    <el-form-item label="亏钱天数" prop="wx">
                        <el-input v-model="ruleForm.wx" style="width: 150px"></el-input>
                    </el-form-item>

                </el-form>

                <span slot="footer" class="dialog-footer" style="margin-right: 100px">

                           <span slot="footer" class="dialog-footer">
              <el-button @click="cancel()" style="width: 300px"   >取 消</el-button>
              <el-button @click="updateUser()" type="primary" style="width: 300px">确定</el-button>
            </span>
            </span>
            </el-dialog>
            <!--修改页面-->

            <br>
            <div class="pages" style="align-content: center">
                <el-pagination
                        @size-change="handleSizeChange"
                        @current-change="handleCurrentChange"
                        :current-page="currentPage"
                        :page-sizes="[3, 6, 9, 12]"
                        :page-size="pagesize"
                        layout="total, sizes, prev, pager, next, jumper"
                        :total="total"
                        style="margin-right: 800px;width: 100px">
                </el-pagination>

            </div>
        </div>
    </div>
</template>

<script>

    export default {
        name: 'ysList',
        inject: ['reload'],
        data () {
            // eslint-disable-next-line no-labels
            // eslint-disable-next-line no-unused-expressions,no-labels
            return {
                pickerOptions: {
                    shortcuts: [{
                        text: '今天',
                        onClick (picker) {
                            picker.$emit('pick', new Date())
                        }
                    }, {
                        text: '昨天',
                        onClick (picker) {
                            const date = new Date()
                            date.setTime(date.getTime() - 3600 * 1000 * 24)
                            picker.$emit('pick', date)
                        }
                    }, {
                        text: '一周前',
                        onClick (picker) {
                            const date = new Date()
                            date.setTime(date.getTime() - 3600 * 1000 * 24 * 7)
                            picker.$emit('pick', date)
                        }
                    }]
                },
                loading: false,
                uuu: [],
                textarea: '',
                ssldun: [],
                sels: [],
                ssld: [],
                sslochen: [],
                users: [

                ],
                fh: [],
                depatment: '',
                depss: [],
                search: '',
                search2: '',
                search3: '',
                dialogVisible: false,
                disabled: true,
                dialogUpdate: false,
                dialogUpdate1: false,
                schArr: [], // 分页数据源
                pagesize: 3,
                currentPage: 1,
                total: 0,

                disablePage: false,
                ruleForm: {
                    schArr: [],
                    tableData: [],
                    search: '',
                    dialogVisible: false,
                    dialogUpdate: false,
                    dialogUpdate1: false,
                    pageSize: 3,
                    currentPage: 1,
                    total: 0,
                    disablePage: false
                },
                ruleForm1: {},
                pages: {

                    sid: '',
                    sgry: '',
                    crzyj: '',
                    crjgb: '',
                    dhbaz: '',
                    zxgs: '',
                    lc: '',
                    wx: '',
                    lj: '',
                    zx: '',
                    xs: '',
                    yid: '',
                    name: '',
                    ylc: '',
                    fh: '',
                    ld: ''
                },
                formInline1: {
                    id: '',
                    fangid: '',
                    fhao: '',
                    fid: ''
                },
                formInline4: {
                    id: '',
                    fangid: '',
                    fhao: '',
                    fid: ''
                },
                formInline2: {
                    id: '',
                    lchen: '',
                    lcid: '',
                    fid: ''
                },
                formInline3: {
                    id: '',
                    ldun: '',
                    lcid: ''
                },
                formInline: {
                    id: '',
                    sgry: '',
                    crzyj: '',
                    crjgb: '',
                    dhbaz: '',
                    zxgs: '',
                    lc: '',
                    wx: '',
                    lj: '',
                    zx: '',
                    xs: '',
                    yid: '',
                    name: '',
                    ylc: '',
                    fh: '',
                    ld: '',
                    fhao: ''

                },
                isDisabled: false
            }
        },
        created () {
            const that = this
            this.getPages()
            this.$axios.post('/selectSpzx7')
                .then(function (response) {
                    console.log(response)
                    that.users = response.data.log
                })

            // this.$axios.post('/selectLoudun')
            //     .then(function (response) {
            //         console.log(response);
            //         that.formInline3 = response.data;
            //     })
            // this.$axios.post('/selectLouc')
            //     .then(function (response) {
            //         console.log(response);
            //         that.formInline2 = response.data;
            //     })
            // this.$axios.post('/selectFang7')
            //   .then(function (response) {
            //     console.log(response)
            //     that.formInline4 = response.data
            //   })
            // this.ruleForm.id = that.formInline4.fhao
        },
        watch: {
            // watch就是用来监控数据变化，只有变化了才会调用定时器的变化
            search () {
                // 调用定时器

                this.timer()
            },
            search2 () {
                // 调用定时器

                this.timer()
            },
            search3 () {
                // 调用定时器

                this.timer()
            }
        },
        // 页面销毁后 停止计时器
        destroyed () {
            clearTimeout(this.timer)
        },
        mounted () {
            this.getDep()
        },
        function2 (val) {
            console.log(val) // 此时打印的直接就是id
        },
        methods: {
            handleLogin () {
                // 防止接口再次调用
                if (this.loading) {
                    return false
                }
                this.loading = true
                // 调用接口,接口完成后，把loading值改为false
                this.loading = false
            },

            function2 (val) {
                this.ruleForm.lcid = val
            },
            function1 () {
                const that = this
                this.$axios.post('/selectYz7')
                    .then(function (response) {
                        that.ssld = response.data.log // 把获取到的数据赋给this.data
                        console.log(that.ssld)
                    })
            },
            function4 () {
                const that = this
                this.$axios.post('/selectLoudun7')
                    .then(function (response) {
                        that.ssldun = response.data.log // 把获取到的数据赋给this.data
                        console.log(that.ssldun)
                    })
            },
            function5 () {
                const that = this
                this.$axios.post('/selectLouc7')
                    .then(function (response) {
                        that.sslochen = response.data.log // 把获取到的数据赋给this.data
                        console.log(that.sslochen)
                    })
            },
            function33 () {
                const that = this
                this.$axios.post('/selectFang7')
                    .then(function (response) {
                        that.fh = response.data // 把获取到的数据赋给this.data
                        console.log(that.fh)
                    })
            },
            function3 (val) {
                const that = this
                this.$axios.post('/selectFang77?fid=' + val)
                    .then(function (response) {
                        that.fh = response.data.log // 把获取到的数据赋给this.data
                        console.log(that.fh)
                    })
                this.ruleForm.fid = val
                this.ruleForm.fhao = ''
            },
            function6 (name) {
                this.ruleForm.yid = name
            },
            function7 (ldun) {
                this.ruleForm.lcid = ldun
            },
            function8 (fhao) {
                this.ruleForm.id = fhao
            },
            handleSizeChange (val) {
                this.getPageData()
                var s = this
                console.log(`每页 ${val} 条`)
                s.pagesize = val
                s.getPageData()
                console.log(s.pagesize)
            },
            handleCurrentChange (val) {
                this.getPageData()
                var ss = this
                console.log(`当前页: ${val}`)
                ss.currentPage = val
                ss.getPageData()
                console.log(ss.currentPage)
            },
            getPageData () {
                console.log('是否yes')
                var thats = this
                let start = (this.currentPage - 1) * this.pagesize
                let end = start + this.pagesize
                this.schArr = thats.users.slice(start, end)
                this.total = thats.users.length
            },

            selsChange (sels) {
                this.sels = sels
            },
            deleteFileOrDirectory () {
                var ids = this.sels.map(item => item.sid).join()// 获取所有选中行的id组成的字符串，以逗号分隔
                this.$confirm('此操作将永久删除该文件及其子文件, 是否继续?', '提示', {
                    confirmButtonText: '确定',
                    cancelButtonText: '取消',
                    type: 'warning'

                }).then(() => {
                        this.$axios.post('deleteSpzx7?ids=' + ids)
                        this.reload()
                        console.log('删除成功')
                    }
                )
            },
            deleteFileOrDirectory1 () {
                var ids = this.sels.map(item => item.sid).join()// 获取所有选中行的id组成的字符串，以逗号分隔
                const that = this
                this.$axios.post('/getSpzaUpdate7?ids=' + ids)
                    .then(function (response) {
                        that.ruleForm = response.data.log // 把获取到的数据赋给this.data
                        console.log(that.ssld)
                    })
                this.dialogUpdate1 = true
            },
            handleEdit (index, row) {
                this.dialogUpdate = true
                this.ruleForm = Object.assign({}, row) // 这句是关键！！！
            },
            handleEdit1 (index, row) {
                this.dialogUpdate = true
                this.ruleForm = Object.assign({}, row) // 这句是关键！！！
            },
            async del (id) {
                const confirmResult = await this.$confirm('此操作将永久删除用户,是否继续?', '提示', {
                    confirmButtonText: '确定',
                    cancelButtonText: '取消',
                    type: 'warning'
                }).catch(err => err)
                // eslint-disable-next-line eqeqeq
                if (confirmResult != 'confirm') {
                    return this.$message.info('已取消删除')
                }
                this.$axios.post('http://localhost:8081/deleteWait7?id=' + id)
                this.reload()
            },
            // handleClose(done) {
            //     this.$confirm('确认关闭？')
            //         .then(  => {
            //             done();
            //         })
            //         .catch(_ => {});
            // },

            cancel () {
                this.dialogUpdate = false
                this.dialogVisible = false
                this.emptyUserData()
            },
            emptyUserData () {
                this.ruleForm = {

                    id: this.ruleForm.id,
                    sgry: this.ruleForm.sgry,
                    crzyj: this.ruleForm.crzyj,
                    crjgb: this.ruleForm.crjgb,
                    dhbaz: this.ruleForm.dhbaz,
                    zxgs: this.ruleForm.zxgs,
                    lc: this.ruleForm.lc,
                    wx: this.ruleForm.wx,
                    lj: this.ruleForm.lj,
                    zx: this.ruleForm.zx,
                    xs: this.ruleForm.xs,
                    ylc: this.ruleForm.ylc,

                    yid: this.ruleForm.yid,
                    name: this.ruleForm.name,
                    fh: this.ruleForm.fh,
                    ld: this.ruleForm.ld
                }
            },
            addUser () {
                let w = this.moment(this.ruleForm1.lc).format('YYYY-MM-DD')

                let postData = this.qs.stringify({
                    wx: this.ruleForm1.wx,
                    crzyj: this.ruleForm1.crzyj,
                    crjgb: this.ruleForm1.crjgb,
                    zxgs: this.ruleForm1.zxgs,
                    lc: w,
                    yid: this.ssld.name,
                    fangid: this.fh.fhao

                })
                this.$axios({
                    method: 'post',
                    url: '/addSpzx7',

                    data: postData
                }).then(response => {
                    this.$axios.post('').then(response => {
                        this.tableData = response.data
                        this.currentPage = 1
                        this.reload()
                        this.$message({
                            type: 'success',
                            message: '已添加!'
                        })
                    }).catch(error => {
                        console.log(error)
                        this.reload()
                    })
                    this.getPages()
                    this.dialogVisible = false
                    console.log(response)
                }).catch(error => {
                    console.log(error)
                    this.reload()
                })
            },
            updateUser (index, row) {
                // wx: this.ruleForm1.wx,
                //   crzyj: this.ruleForm1.crzyj,
                //   crjgb: this.ruleForm1.crjgb,
                //   zxgs: this.ruleForm1.zxgs,
                //   lc: this.ruleForm1.lc,
                //   yid: this.ssld.name,
                //   fangid: this.formInline4.fhao
                sessionStorage.setItem('sid', row)
                let w = this.moment(this.ruleForm.lc).format('YYYY-MM-DD')
                let postData = this.qs.stringify({
                    sid: this.ruleForm.sid,
                    crjgb: this.ruleForm.crjgb,
                    zxgs: this.ruleForm.zxgs,
                    lc: w,
                    wx: this.ruleForm.wx,
                    yid: this.ruleForm.yid,
                    fangid: this.ruleForm.id,

                    crzyj: this.ruleForm.crzyj
                })

                this.$axios({

                    method: 'post',
                    url: '/updateSpzx77',
                    data: postData
                }).then(response => {
                    this.handleCurrentChange()
                    this.cancel()
                    this.$message({
                        type: 'success',
                        message: '更新成功!'
                    })
                    console.log(response)
                    this.reload()
                }).catch(error => {
                    this.$message({
                        type: 'success',
                        message: '更新失败!'
                    })
                    console.log(error)
                    this.reload()
                })
            },

            updateUser1 (index, row) {
                this.loadingbut = true
                this.loadingbuttext = '审核中...'
                this.isDisabled = true
                // wx: this.ruleForm1.wx,
                //   crzyj: this.ruleForm1.crzyj,
                //   crjgb: this.ruleForm1.crjgb,
                //   zxgs: this.ruleForm1.zxgs,
                //   lc: this.ruleForm1.lc,
                //   yid: this.ssld.name,
                //   fangid: this.formInline4.fhao
                sessionStorage.setItem('sid', row)
                let postData = this.qs.stringify({
                    sid: sessionStorage.getItem('sid'),
                    // sgry: this.ruleForm.sgry,
                    crzyj: 1

                    // crjgb: this.ruleForm.crjgb,
                    // dhbaz: this.ruleForm.dhbaz,
                    // zxgs: this.ruleForm.zxgs,
                    // lc: this.ruleForm.lc,
                    // wx: this.ruleForm.wx,
                    // lj: this.ruleForm.lj,
                    // zx: this.ruleForm.zx,
                    // xs: this.ruleForm.xs,
                    // ylc: this.ruleForm.ylc,
                    // yid: this.ruleForm.yid,
                    // fangid: this.ruleForm.id,
                    // loucid: this.ruleForm.fid,
                    // loudid: this.ruleForm.lcid
                })

                this.$axios({

                    method: 'post',
                    url: '/updateSpzx7',
                    data: postData
                }).then(response => {
                    this.handleCurrentChange()
                    this.cancel()
                    this.$message({
                        type: 'success',
                        message: '催缴已发送!'

                    })

                    console.log(response)
                    this.reload()
                }).catch(error => {
                    this.$message({
                        type: 'success',
                        message: '更新失败!'
                    })
                    console.log(error)
                    this.reload()
                })
                // this.loadingbut = false;
                // this.loadingbuttext = '确定';
            },
            onSearch () {
                let postData = this.qs.stringify({
                    fhao: this.search,
                    name: this.search2,
                    zxgs: this.search3
                })
                this.$axios({
                    method: 'post',
                    url: 'http://localhost:8001/getByName7',
                    data: postData
                }).then(response => {
                    this.$axios({
                        method: 'post',
                        url: 'http://localhost:8001/rows7',
                        data: postData
                    }).then(response => {
                        this.total = response.data
                    })
                    this.users = response.data
                    this.disablePage = true
                }).catch(error => {
                    console.log(error)
                })
            },
            getPages () {
                let postData = this.qs.stringify({
                    anum: this.search,
                    astime: this.search2,
                    artime: this.search3
                })
                this.$axios({
                    method: 'post',
                    url: 'http://localhost:8001/rows7',
                    data: postData
                }).then(response => {
                    this.total = response.data
                }).catch(error => {
                    console.log(error)
                })
            },
            refreshData () {
                this.reload()
            },
            timer () {
                return setTimeout(() => {
                    this.onSearch()
                }, 100)
            }
        }
    }
</script>
<style scoped>
    .search_name{
        width: 200px;
    }

    .pages{
        margin: 0px;
        padding: 0px;
        text-align: right;
    }
</style>
